package com.jiangsong.mapper;

import com.jiangsong.entity.FeeRateHis;
import org.apache.ibatis.annotations.Insert;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

/**
 * @author jiangsong
 * @date 2021/4/15
 **/

@Mapper
public interface FeeRateHisMapper {


    @Select("select * from fee_rate_his where acc_no = #{accNo}")
    List<FeeRateHis> getFeeRateHisByAccNo(String accNo);

    /**
     * 批量插入数据
     */
    @Insert("insert into fee_rate_his (acc_no, proj_no, level,proj_desc,amt,rate,charge_date,trace_id,serv_no,kind,date,modified_desc) values (#{feeRateHis.accNo},#{feeRateHis.projNo},#{feeRateHis.level},#{feeRateHis.projDesc},#{feeRateHis.amt},#{feeRateHis.rate},#{feeRateHis.chargeDate},#{feeRateHis.traceId},#{feeRateHis.servNo},#{feeRateHis.kind},#{feeRateHis.date},#{feeRateHis.modifiedDesc})")
    int insertOne(@Param("feeRateHis") FeeRateHis feeRateHis);

}
